import { log } from "console"


let sym1 = Symbol('redis_key')
let sym2 = Symbol()
let sym3 = Symbol()
let sym4 = Symbol()
let sym5 = Symbol()

if (sym1 === sym3) {
  console.log('相等');

} else {
  console.log('不相等');
}


let obj2322 = {
  [sym1]: 'sdsss1',
  [sym2]: 'sdsss1',
}





console.log('---------------');

console.log(obj2322[sym1]);
// for (const i in obj222) {
//   console.log(i);

// }

// console.log(Object.values(obj222));


// for (const element of Object.values(obj222)) {
//     console.log(element);

// }
const COLOR_RED = Symbol();
const COLOR_GREEN = Symbol();

function getComplement(color: any) {
  switch (color) {
    case COLOR_RED:
      return COLOR_GREEN;
    case COLOR_GREEN:
      return COLOR_RED;
    default:
      throw new Error('Undefined color');
  }
}




